<template>
  <div class="tz">
    <div style="padding-left: 10px;margin-top: -10%;">
      <h4>通知</h4>
    </div>
    <van-tabbar v-model="active" @change="onChange">
      <van-tabbar-item icon="wap-home-o">首页</van-tabbar-item>
      <van-tabbar-item icon="comment-o">日志</van-tabbar-item>
      <van-tabbar-item icon="volume-o">通知</van-tabbar-item>
      <van-tabbar-item icon="manager-o">我的</van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {
  data() {
    return {
      active: 2,
      phone:""
    };
  },
  created(

) {
  this.phone = this.$route.query.phone;
},
  methods: {
    onChange(index) {
      if (index === 0) {
        this.$router.push("/home?phone=" +this.phone );
      }
      if (index === 1) {
        this.$router.push("/log?phone=" +this.phone );
      }
      if (index === 3) {
        this.$router.push("/my?phone=" +this.phone );
      }
    },
  },
};
</script>